import config from "@/config"
import http from "@/utils/request"

export const getUserList = (data) => {
	return http.post(`${config.API_SYS_BASE}/user/list`, data).catch((err) => {
		console.log(err)
	});
}
export const getUserById = (data) => {
	return http.post(`${config.API_SYS_BASE}/user/getUser`, data).catch((err) => {
		console.log(err)
	});
}
export const addOrUpdate = (data) => {
	return http.post(`${config.API_SYS_BASE}/user/addOrUpdate`, data).catch((err) => {
		console.log(err)
	});
}
export const deleteUser = (data) => {
	return http.post(`${config.API_SYS_BASE}/user/delete`, data).catch((err) => {
		console.log(err)
	});
}
export const resettingPassword = (data) => {
	return http.post(`${config.API_SYS_BASE}/user/resettingPassword`, data).catch((err) => {
		console.log(err)
	});
}
export const changePassword = (data) => {
	return http.post(`${config.API_SYS_BASE}/authorization/changePassword`, data).catch((err) => {
		console.log(err)
	});
}
export const permissions = (data) => {
	return http.post(`${config.API_SYS_BASE}/authorization/permissions`, data).catch((err) => {
		console.log(err)
	});
}
export const resetBindingIp = (data) => {
	return http.post(`${config.API_SYS_BASE}/user/resetBindingIp`, data).catch((err) => {
		console.log(err)
	});
}

